<nav class="navbar navbar-expand-sm navbar-light bg-light">
    <a class="navbar-brand" href="#">
        <img src="/admin/img/logox.png" width="200" height="30" alt="">
        个人中心
    </a>
    <div class="navbar-nav">
        <a href="/" class="nav-link">选题首页</a>
    </div>

    <ul class="navbar-nav ml-auto">
        <li class="nav-item dropdown">
            <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" data-toggle="dropdown">
                <% if (user.role == 1) { %>
                    欢迎回来！管理员：<%=user.username%>
                <% } %>
                <% if (user.role == 2) { %>
                    欢迎回来！系负责人：<%=user.username%>
                <% } %>
                <% if (user.role == 3) { %>
                    欢迎回来！导师：<%=user.username%>
                <% } %>
                <% if (user.role == 4) { %>
                    欢迎回来！学生：<%=user.username%>
                <% } %>
            </a>
            <div class="dropdown-menu dropdown-menu-right">
                <a class="dropdown-item" href="/admin">个人中心</a>
                <a class="dropdown-item" href="/user/logout">退出</a>
            </div>
        </li>
    </ul>
</nav>